using UnityEngine;

public class Award : MonoBehaviour
{
    public enum AwardType
    {
        SuperGun,
        Boom
    }

    public float speed = 0.5f;

    public AwardType awardType = AwardType.SuperGun;
    // 奖励类型的枚举类


    // Start is called before the first frame update
    void Start()
    {
    }

    // Update is called once per frame
    void Update()
    {
        //向下移动
        transform.Translate(Vector3.down * speed * Time.deltaTime);
        // check and destroy award
        if (transform.position.y < -4.8f)
        {
            Destroy(this.gameObject);
        }
    }
}